<div style="text-align: center">
    <img src="{$qrcode}"  id="saveImg" >
</div>
<script>
    function getImage(){
        return document.getElementById("saveImg").src;
    }
</script>